package com.hospital.doctor.controller;

import com.hospital.common.result.R;
import com.hospital.doctor.domain.DepartmentInfo;
import com.hospital.doctor.service.EltDepartmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @Author：zhuzhujiang
 * @Description:
 * @name：EltDepartmentController
 * @Date：2024/10/20 19:41
 */
@RestController
@RequestMapping("/department")
public class EltDepartmentController {

    @Autowired
    private EltDepartmentService eltDepartmentService;

    /**
     * 查询部门信息
     * @param departmentId
     * @return
     */
    @GetMapping("/getDepartmentInfo/{departmentId}")
    public R<DepartmentInfo> getDepartmentInfo(@PathVariable("departmentId") Integer departmentId){

        DepartmentInfo departmentInfo = eltDepartmentService.getDepartmentInfo(departmentId);

        return R.success(departmentInfo);
    }




}
